#pragma once
#include"const.h"
#include "Singleton.h"
#include "MySqlDao.h"
class MysqlMgr:public Singleton<MysqlMgr>
{
	friend class Singleton<MysqlMgr>;
public:
	~MysqlMgr();
	int ResUser(const std::string& name, const std::string& email, const std::string& pwd);
	bool CheckEmail(const std::string& name, const std::string& email);
	bool UpdatePwd(const std::string& email, const std::string& newpwd);
	bool CheckPwd(const std::string& email, const std::string pwd, UserInfo& userInfo);
	
private:
	MysqlMgr();
	MySqlDao _dao;

};

